{{!
  Copyright (c) HashiCorp, Inc.
  SPDX-License-Identifier: BUSL-1.1
~}}

<svg data-test-gauge-svg role="img" height={{this.height}} title="gauge chart">
  <defs>
    <linearGradient x1="0" x2="1" y1="0" y2="0" class="{{this.chartClass}}" id="{{this.fillId}}">
      <stop class="start" offset="0%" />
      <stop class="end" offset="100%" />
    </linearGradient>
    <clipPath id="{{this.maskId}}">
      <path class="fill" d="{{this.valueArc}}" />
    </clipPath>
  </defs>
  <g class="canvas {{this.chartClass}}">
    <path class="background" d="{{this.backgroundArc}}" />
    <rect class="area" x="0" y="0" width="100%" height="100%" fill="url(#{{this.fillId}})" clip-path="url(#{{this.maskId}})" />
  </g>
</svg>
<div class="metric">
  <h3 data-test-label class="label">{{this.label}}</h3>
  <p data-test-percentage class="value">{{format-percentage this.value total=this.total complement=this.complement}}</p>
</div>
